const getters = {
  // 普通函数写成箭头函数
  // function sidebar(state){
  //   return  state.app.sidebar
  // }
  sidebar: state => state.app.sidebar,
  device: state => state.app.device,
  token: state => state.user.token,
  avatar: state => state.user.userInfo.staffPhoto,
  name: state => state.user.userInfo.username,
  userId: state => state.user.userInfo.userId
  // getters相当于 vuex中计算属性
}
export default getters
